home *** CD-ROM | disk | FTP | other *** search
/ Internet 1996 World Exposition / park.org.s3.amazonaws.com.7z / park.org.s3.amazonaws.com / Japan / Panasonic- / funcity / tokyo / e / boxing.dcr / 00003_national script.ls < prev    next >
Encoding:
Text File  |  2017-09-21  |  2.5 KB  |  87 lines

  1. property snum, cnum, acount, dcount
  2. global naobj, kidobj
  3.  
  4. on birth me, lh, lv, spnum
  5.   set snum to spnum
  6.   set cnum to the number of cast "na_de.loop"
  7.   set the puppet of sprite snum to 1
  8.   set the type of sprite snum to 1
  9.   set the castNum of sprite snum to cnum
  10.   set the ink of sprite snum to 36
  11.   set the foreColor of sprite snum to 255
  12.   set the backColor of sprite snum to 0
  13.   set the locH of sprite snum to lh
  14.   set the locV of sprite snum to lv
  15.   set acount to 0
  16.   set dcount to 0
  17.   return me
  18. end
  19.  
  20. on namove me
  21.   if the frame >= label("check") then
  22.     if cnum <> the number of cast "na_down" then
  23.       set cnum to the number of cast "na_de.loop"
  24.       set the castNum of sprite snum to cnum
  25.     end if
  26.     exit
  27.   end if
  28.   set acount to acount - 1
  29.   if acount = 8 then
  30.     puppetSound(4, the number of cast "p_hit")
  31.   else
  32.     if acount <= 0 then
  33.       if dcount = 9 then
  34.         set cnum to the number of cast "na_down"
  35.         puppetSound("win")
  36.         set dcount to 10
  37.         showscore()
  38.       else
  39.         if dcount < 9 then
  40.           set ar to random(40 - dcount)
  41.           if cnum <> the number of cast "na_de.loop" then
  42.             set cnum to the number of cast "na_de.loop"
  43.             set acount to 1 + random(4)
  44.           else
  45.             if ar > 28 then
  46.               set cnum to the number of cast "na_gu"
  47.               set acount to 3 + random(3)
  48.             else
  49.               if ar <= 3 then
  50.                 set cnum to the number of cast "na_PR"
  51.                 puppetSound(4, the number of cast "p_play")
  52.                 if the cnum of kidobj = the number of cast "kid_de.loop" then
  53.                   kiddamage(kidobj)
  54.                   set acount to 10
  55.                 else
  56.                   set acount to 5 + random(3)
  57.                 end if
  58.               else
  59.                 if ar <= 6 then
  60.                   set cnum to the number of cast "na_PL"
  61.                   puppetSound(4, the number of cast "p_play")
  62.                   if the cnum of kidobj = the number of cast "kid_de.loop" then
  63.                     kiddamage(kidobj)
  64.                     set acount to 10
  65.                   else
  66.                     set acount to 5 + random(3)
  67.                   end if
  68.                 end if
  69.               end if
  70.             end if
  71.           end if
  72.         end if
  73.       end if
  74.       set the castNum of sprite snum to cnum
  75.     end if
  76.   end if
  77. end
  78.  
  79. on nadamage me
  80.   set cnum to the number of cast "na_da"
  81.   set acount to 6
  82.   set the castNum of sprite snum to cnum
  83.   set dcount to dcount + 1
  84.   set the puppet of sprite (dcount + 10) to 1
  85.   set the blend of sprite (dcount + 10) to 30
  86. end
  87.